<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>课程表</title>
    <jsp:include page="/static/common/easyui-header.jsp"></jsp:include>
    <script type="text/javascript" src="/static/js/views/schedule.js"></script>
</head>
<body>
<%--使用layout布局--%>
<div id="schedule" class="easyui-layout" fit="true">
    <div id="west" data-options="region:'west',split:true,title:''" style="width: 200px">
        <div id="cc2" class="easyui-layout" fit="true">
            <div id="north" data-options="region:'north',split:true,title:'日期',collapsible:false,minHeight:300">
                <div id="calendar" class="easyui-calendar" fit="true"></div>
            </div>
            <div id="south" data-options="region:'south',split:true,title:'班级',collapsible:false,minHeight:190,">
                <table id="cg_datagrid"></table>
            </div>
        </div>
    </div>
    <div data-options="region:'center'">
        <table id="schedule_datagrid"></table>
        <div id="schedule_toolbar">
            <a class="easyui-linkbutton" iconCls="icon-reload" plain="true" data-cmd="reload">全部</a>
            <input id="btn_classgrade" class="easyui-combobox"
                   data-options="width:'150px',url:'/classgrade/queryAll',valueField:'id',textField:'name',prompt:'班级',panelHeight:'auto',onSelect: function(rec){
                var url = '/classroom/queryClassoomByClassgradeId?id='+rec.id;
                $('#btn_classroom').combobox('clear');
                $('#btn_classroom').combobox('reload', url);
        },onUnselect:function(){
                var url = '/classroom/listActiveRoom';
                $('#btn_classroom').combobox('clear');
                $('#btn_classroom').combobox('reload', url);
        }"
                   name="classId">
            <input id="btn_classroom" class="easyui-combobox"
                   data-options="url:'/classroom/queryAll',valueField:'id',textField:'name',panelHeight:'auto',prompt:'教室'"
                   name="roomId">
            <input id="btn_teacher" class="easyui-combobox"
                   data-options="prompt:'上课教师',url:'/employee/selectTeacherByRoleIdWithSchedle?id=2',valueField:'id',textField:'realName',panelHeight:'auto'"
                   name="employeeId"><br/>
            &emsp;&emsp;&emsp;&emsp;&emsp;
            <input id="btn_beginDate" type="text" class="easyui-datebox" name="beginDate" data-options="width:'150px'"/>
            到 <input type="text" class="easyui-datebox"
                     name="endDate" id="btn_endDate" data-options="width:'150px'"/>&emsp;
            <a class="easyui-linkbutton" iconCls="icon-search" plain="true" data-cmd="searchForSchedule">查询</a>
        </div>
    </div>
</div>
</body>
</html>
